//
//  MSShimmerContextView.swift
//  MSShimmer
//
//  Created by zz on 24.7.25.
//

import UIKit

// 空白页面
public class MSShimmerContextView: MSShimmerContainerView {
    public override func start() {
        // 不做处理
    }
}

// 空白容器页面
open class MSShimmerBoardContainerView: MSShimmerContainerView {
    public func msAddSubView(_ view:MSShimmerContainerView) {
        addSubview(view)
    }
    
    public override func start() {
        let subViewArray = self.subviews
        for subView in subViewArray {
            if let msShimmer = subView as? MSShimmerContainerView {
                msShimmer.start()
            }
        }
    }
    
    public override func stop() {
        let subViewArray = self.subviews
        for subView in subViewArray {
            if let msShimmer = subView as? MSShimmerContainerView {
                msShimmer.stop()
            }
        }
        self.removeFromSuperview()
    }
}
